import request from '@/utils/request'

// 查询客商基本信息列表
export function listTbCustomers(query) {
  return request({
    url: '/information/tbCustomers/list',
    method: 'get',
    params: query
  })
}

//查询客户/供应商信息
export function CustomerCompanyTypeAll(companyType){
  return request({
    url:'/information/tbCustomers/CompanyTypeAll/' + companyType,
    method:'get'
  })
}

// 查询客商基本信息详细
export function getTbCustomers(id) {
  return request({
    url: '/information/tbCustomers/' + id,
    method: 'get'
  })
}

// 新增客商基本信息
export function addTbCustomers(data) {
  return request({
    url: '/information/tbCustomers',
    method: 'post',
    data: data
  })
}

// 修改客商基本信息
export function updateTbCustomers(data) {
  return request({
    url: '/information/tbCustomers',
    method: 'put',
    data: data
  })
}

// 删除客商基本信息
export function delTbCustomers(id) {
  return request({
    url: '/information/tbCustomers/' + id,
    method: 'delete'
  })
}
